Book Contents

Quick reference to operators

Symbol

Operator

Example

+

addition

tag1 + tag2

-

subtraction

tag1 - tag2

*

multiplication

tag1 * tag2

/

division

tag1 / tag2

MOD, %

modulus (remainder)

tag1 % tag2

**

exponent

tag1 ** 2

EQ, ==

equal

tag1 == tag2

NE, <>

not equal

tag1 <> tag2

LT, <

less than

tag1 < tag2

GT, >

greater than

tag1 > tag2

LE, <=

less than or equal to

tag1 <= tag2

GE, >=

greater than or equal to

tag1 >= tag2

AND, &&

and

(tag1 < tag 2) AND (tag1 = 5)

OR, ||

or

(tag1 = 5) OR (tag1 = 10)

NOT

negation

NOT(tag1 > tag2)

&

AND

tag1 & 07

|

inclusive OR

tag2 | tag1

^

exclusive OR (XOR)

tag1 ^ 01

>>

right shift

tag1 >> 1

<<

left shift

tag1 << 2

~

complement

~ tag1

See also

About expressions

Quick reference to math functions

Quick reference to security functions